const Base = require('./base.js');

module.exports = class extends Base {
  async postsAction() {
    const where = this.get('category,keywords,status,author');
    const posts = await think.model('contents').getPosts(where, this.get('page'), this.get('size'));
    this.assign('posts', posts);
    return this.display();
  }

  pagesAction() {
    return this.display();
  }

  commentsAction() {
    return this.display();
  }

  categoriesAction() {
    return this.display();
  }

  tagsAction() {
    return this.display();
  }

  mediasAction() {
    return this.display();
  }

  usersAction() {
    return this.display();
  }
};
